﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using log4net;

namespace AcctrueWMS.Foundation.Common
{
    public class LoggerManager
    {
        static ILog logger = GetLogger();
        /// <summary>
        /// 记录信息日志
        /// </summary>
        /// <returns></returns>
        public static ILog GetLogger()
        {            
           return LogManager.GetLogger(typeof(LoggerManager));  
        }
   
       /// <summary>
        /// 记录异常日志
       /// </summary>
        /// <param name="name">异常日志路径，根据web.config中配置的一致，如：logerror</param>
       /// <returns></returns>
        public static ILog GetLogger(string name)
        {
            return LogManager.GetLogger(name);         
        }
    }
}
